/*
 * Copyright (c) Zhongkehonglue Technologies Co., Ltd. 2025. All rights reserved.
 * Description: Implementation of functions related to the DMC module.
 * Author: wangchunyang
 * Create: 2025-05-23
 */

#ifndef DMC_AVT_H
#define DMC_AVT_H

#include <string>
#include <vector>
#include <mutex>

#include "dmcParseXml.h"
#include "dmcApiTypes.h"

namespace DlnaDmc {

dmc_int32 DmcSetAvTransportURI(dmc_uint32 deviceId, dmc_uint32 instanceId,
    const std::string &uri, const std::string &metaData);
dmc_int32 DmcPlay(dmc_uint32 deviceId, dmc_uint32 instanceId, const std::string &playSpeed);
dmc_int32 DmcPause(dmc_uint32 deviceId, dmc_uint32 instanceId);
dmc_int32 DmcStop(dmc_uint32 deviceId, dmc_uint32 instanceId);
dmc_int32 DmcSeek(dmc_uint32 deviceId, dmc_uint32 instanceId, DmcSeekMode seekMode,
    const std::string &seekTarget);
dmc_int32 DmcGetPositionInfo(dmc_uint32 deviceId, dmc_uint32 instanceId, DmrTrackPosition &trackPos);
dmc_int32 DmcGetTrackInfo(IXML_Document *resultDoc, DmrTrackPosition &trackPos);
dmc_int32 DmcGetTimeAndCountInfo(IXML_Document *resultDoc, DmrTrackPosition &trackPos);
dmc_int32 DmcConvAscToUInt(unsigned char *asc, dmc_uint32 &val);
bool IsWhiteSpace(unsigned char ch);
dmc_int32 DmcGetPositionResult(IXML_Document *resultDoc, DmrTrackPosition &trackPos);
dmc_int32 DmcGetTransportInfo(dmc_uint32 deviceId, dmc_uint32 instanceId,
    DmcTransportState &transportState, DmcTransportStatus &transportStatus, std::string &playSpeed);
}
#endif /* DMC_AVT_H */

